package com.maven.front.controller.manageEduuser;

import com.maven.front.bean.EduUser;
import com.maven.front.bean.Result;
import com.maven.front.service.manageEduuser.EduuserService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;


import java.util.List;

@RestController
@RequestMapping("admin/eduUser")
@Slf4j
public class EduuserController {

    @Autowired
    private EduuserService eduuserService;
    @PostMapping("list")
    public Result list(EduUser eduUser){
        List<EduUser> list=eduuserService.list(eduUser);
        if(list==null){
            return  new Result(400,"查询失败",null);
        }else {
            return new Result(200,"查询成功",list);
        }
    }

}
